Go Back   NexusDB Newsgroups > Support Newsgroups > nexusdb.public.support.sql
Log in
FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
Thread Tools Display Modes
  #1  
Old 31st October 2022, 09:28 PM
roseweb roseweb is offline
Junior Member
 
Join Date: Feb 2017
Posts: 3
Unhappy How to apply [Apply when modifying] with DDL command? 어떻게 하면 DDL 명령어로 [수정 시 적용] 을 적용함

I want to apply Apply on Modify with NEXUS DDL command to each table as check. (Apply on Modify with NEXUS DDL 명령을 각 테이블에 체크로 적용하고 싶습니다.)


It can be applied as follows with the DELPHI command,
(DELPHI 명령어로 다음과 같이 적용할 수 있으며,)
===============================================
SQL Statement :
"InsertTime" TIMESTAMP DEFAULT CURRENT_TIMESTAMP DESCRIPTION 'Insert Time',
"UpdateTime" TIMESTAMP DEFAULT CURRENT_TIMESTAMP DESCRIPTION 'Update Time',
"UpdateUser" NVARCHAR(50) DEFAULT CURRENT_USER DESCRIPTION 'Lasted Update User',

Delphi :
with AddField('InsertTime', 'Insert Time', nxtDateTime, 0, 0, False) do
AddDefaultValue(TnxCurrentDateTimeDefaultValueDesc riptor);

with AddField('UpdateTime', 'Update Time', nxtDateTime, 0, 0, False) do
with AddDefaultValue(TnxCurrentDateTimeDefaultValueDesc riptor) as TnxCurrentDateTimeDefaultValueDescriptor do begin
ApplyOnModify := True;
OverwriteNonNull := True;
end;
with AddField('UpdateUser', 'Lasted Update User', nxtWideString, 50, 0, False) do
with AddDefaultValue(TnxCurrentUserDefaultValueDescript or) as TnxCurrentUserDefaultValueDescriptor do begin
ApplyOnModify := True;
OverwriteNonNull := True;
end;

SQL statement - only Table Insert
Delphi - insert or modify and ALL
===============================================

I want to apply Apply on modify to the entire table in batches with DDL command
(DDL 명령을 사용하여 일괄적으로 전체 테이블에 수정 시 적용을 적용하고 싶습니다.)
Is there no way?
(방법이 없을까요?)
  #2  
Old 2nd November 2022, 01:56 PM
Eivind Eivind is offline
Administrator
 
Join Date: Mar 2008
Posts: 226
Default

Quote:
Originally Posted by roseweb View Post
I want to apply Apply on Modify with NEXUS DDL command to each table as check. (Apply on Modify with NEXUS DDL 명령을 각 테이블에 체크로 적용하고 싶습니다.)


It can be applied as follows with the DELPHI command,
(DELPHI 명령어로 다음과 같이 적용할 수 있으며,)
===============================================
SQL Statement :
"InsertTime" TIMESTAMP DEFAULT CURRENT_TIMESTAMP DESCRIPTION 'Insert Time',
"UpdateTime" TIMESTAMP DEFAULT CURRENT_TIMESTAMP DESCRIPTION 'Update Time',
"UpdateUser" NVARCHAR(50) DEFAULT CURRENT_USER DESCRIPTION 'Lasted Update User',

Delphi :
with AddField('InsertTime', 'Insert Time', nxtDateTime, 0, 0, False) do
AddDefaultValue(TnxCurrentDateTimeDefaultValueDesc riptor);

with AddField('UpdateTime', 'Update Time', nxtDateTime, 0, 0, False) do
with AddDefaultValue(TnxCurrentDateTimeDefaultValueDesc riptor) as TnxCurrentDateTimeDefaultValueDescriptor do begin
ApplyOnModify := True;
OverwriteNonNull := True;
end;
with AddField('UpdateUser', 'Lasted Update User', nxtWideString, 50, 0, False) do
with AddDefaultValue(TnxCurrentUserDefaultValueDescript or) as TnxCurrentUserDefaultValueDescriptor do begin
ApplyOnModify := True;
OverwriteNonNull := True;
end;

SQL statement - only Table Insert
Delphi - insert or modify and ALL
===============================================

I want to apply Apply on modify to the entire table in batches with DDL command
(DDL 명령을 사용하여 일괄적으로 전체 테이블에 수정 시 적용을 적용하고 싶습니다.)
Is there no way?
(방법이 없을까요?)
In SQL, you would apply changes on existing records using the UPDATE ... statement.

To apply changes for new or modified records, you write a TRIGGER. See our SQL docs for syntax.


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Modifying NXImporter Gary Mugford nexusdb.public.support 8 13th August 2018 07:12 PM
Fastcube 2. Does someone is using it ? How to apply a range filter bycode ? Roberto Nicchi nexusdb.public.discussions 1 5th November 2016 04:27 AM
Table structure : Apply Default Paul Coshott nexusdb.public.support 1 16th June 2010 04:40 PM
apply TOSTRING to a datetime field Jago Post nexusdb.public.support.sql 9 16th May 2006 06:23 PM
DATETIME Apply Range Mike & Janet Larke nexusdb.public.support.sql 3 12th December 2003 06:23 AM


All times are GMT +11. The time now is 01:38 AM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2023, Jelsoft Enterprises Ltd.