Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » DBISAM Technical Support » Support Forums » DBISAM SQL » View Thread |
Messages 1 to 2 of 2 total |
Extract in insert |
Thu, Aug 28 2008 3:53 AM | Permanent Link |
Denis Gottardello | I have a timestamp DateTime value.
I must insert it in a table with 3 Integer columns year: Integer, month: Integer, Day: Integer (3 colums) Can I do insert into MyTable (Year, Month, Day) values (exctract (year from :PDateTime), exctract (month from :PDateTime)), exctract (day from :PDateTime)) |
Thu, Aug 28 2008 7:29 AM | Permanent Link |
Fernando Dias Team Elevate | Denis,
> Can I do > Apart from some typos, yes. Here it is with the correct syntax: insert into MyTable (Year, Month, Day) values( extract(year from :PDateTime), extract(month from :PDateTime), extract (day from :PDateTime) ) I'm assuming you are using this statement in a TDBISAMQuery component, PDateTime is an ftDateTime parameter and you want to insert one single row each time you execute the query. -- Fernando Dias [Team Elevate] |
This web page was last updated on Saturday, April 27, 2024 at 08:52 PM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |