JDB is binary internally. So backup/replication would work,
but for syncing/merging you'd need an import/export round trip
to a text format like CSV without auto/trans ids.



> From: Alex Rufon <[email protected]>
> 
> :) Thanks for the heads-up in import/export in Northwind. I am planning on 
> building something like that to handle backup/restore of my data.
> 
> I also have this crazy idea in my head about putting a JDB database inside 
> git 
> (DVCS) to handle database replication and synchronization. Heheheh ... don't 
> know if it would work because of autoid's and tranids. ;)
> 
> -----Original Message-----
> From: [email protected] [mailto:[email protected]] On 
> Behalf Of Oleg Kobchenko
> Sent: Monday, November 30, 2009 5:55 PM
> To: General forum
> Subject: Re: [Jgeneral] JDB: DateTime datatype
> 
> See also the Norhtwind example from data/jdb addon,
> for the purpose of treating import/export.
> It converts dates from CSV format "1992-05-01 0:00:00"
> to integers "19920501". But only date is considered, no time.
> So float would be natural include the time part.
> This format is user readable, but does not support direct
> arithmetic, unlike MS-SQL/VB. So the choice may depend on
> your purpose.
> 
> 
> 
> > From: Alex Rufon 
> > 
> > I did settle on using float so one of my typical tables definition looks 
> > like 
> > this:
> > NB. ---------------------------------------------------------
> > NB. Worlds
> > NB. Each world is a sumulation ...
> > Worlds=: noun define
> > WorldID varchar;
> > Description varchar
> > CreatedBy varchar
> > CreateDate float
> > )
> > 
> > In the long run, it would be better to keep it as a number then convert it 
> > to 
> > strings when needed.
> > 
> > 
> > -----Original Message-----
> > From: [email protected] [mailto:[email protected]] 
> > On 
> > Behalf Of Jim Russell
> > Sent: Sunday, November 29, 2009 10:59 PM
> > To: General forum
> > Subject: Re: [Jgeneral] JDB: DateTime datatype
> > 
> > I'd stick with the ms-SQL convention of float days and fractions since  
> > some base date (1/1/1900). It should make date arithmetic (datediff,  
> > dateadd) easier. Datetime or smalldatetime depending on your need for  
> > millisecond precision.
> > 
> > 
> > 
> > On Nov 29, 2009, at 9:55 AM, Alex Rufon  
> > wrote:
> > 
> > > As I am rebuilding my database from MS-SQL to JDB, I stumbled upon a  
> > > question. How do I store DateTime in JDB?
> > >
> > > My initial reaction was to store it as a string in this format:  
> > > "YYYY-MM-DD HH:MM:SS" but then I could also store them as a floating  
> > > number in this format YYYYMMDD.datefraction
> > >
> > > Both ways have pros and cons and in my tally they are about the  
> > > same ... anybody has an opinion?
> > >
> > > Thanks.
> > >
> > >
> > > ----------------------------------------------------------------------
> > > For information about J forums see http://www.jsoftware.com/forums.htm
> > ----------------------------------------------------------------------
> > For information about J forums see http://www.jsoftware.com/forums.htm
> > ----------------------------------------------------------------------
> > For information about J forums see http://www.jsoftware.com/forums.htm
> 
> 
> 
>       
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm



      
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to