~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/item/ref_null_helper.cc

  • Committer: Lee Bieber
  • Date: 2010-11-07 19:34:48 UTC
  • mfrom: (1910.1.2 build)
  • Revision ID: kalebral@gmail.com-20101107193448-64kdu912qej354sh
Merge Stewart - including adapting and expanding the "differences from mysql" page from the wiki.
Merge Stewart - fix bug 668143: drizzleslap with --commit runs second iteration data load in a transaction

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* -*- mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; -*-
2
2
 *  vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
3
3
 *
4
 
 *  Copyright (C) 2008 Sun Microsystems, Inc.
 
4
 *  Copyright (C) 2008 Sun Microsystems
5
5
 *
6
6
 *  This program is free software; you can redistribute it and/or modify
7
7
 *  it under the terms of the GNU General Public License as published by
18
18
 */
19
19
 
20
20
#include "config.h"
21
 
 
22
21
#include <drizzled/item/ref.h>
23
22
#include <drizzled/item/ref_null_helper.h>
24
23
#include <drizzled/item/subselect.h>
25
 
#include <drizzled/lex_string.h>
26
24
 
27
25
namespace drizzled
28
26
{
45
43
}
46
44
 
47
45
 
48
 
type::Decimal *Item_ref_null_helper::val_decimal(type::Decimal *decimal_value)
 
46
my_decimal *Item_ref_null_helper::val_decimal(my_decimal *decimal_value)
49
47
{
50
48
  assert(fixed == 1);
51
 
  type::Decimal *val= (*ref)->val_decimal_result(decimal_value);
 
49
  my_decimal *val= (*ref)->val_decimal_result(decimal_value);
52
50
  owner->was_null|= null_value= (*ref)->null_value;
53
51
  return val;
54
52
}
70
68
  return tmp;
71
69
}
72
70
 
73
 
bool Item_ref_null_helper::get_date(type::Time &ltime, uint32_t fuzzydate)
 
71
bool Item_ref_null_helper::get_date(DRIZZLE_TIME *ltime, uint32_t fuzzydate)
74
72
{
75
73
  return (owner->was_null|= null_value= (*ref)->get_date(ltime, fuzzydate));
76
74
}