Create SurrogateKey

Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Create SurrogateKey
# 1  
Old 09-23-2011
Create SurrogateKey

Hi Everyone,

I have a file with 10000 records. For all the source records I need to create a Unique key values.
Day 1
I am loading the data into target table. Now it has 10000 records with unique surrogate key
Day 2
I am getting again 5000 new records in my source file. Now I need to start my surrogate key value form 10001 onwards.

I need to create script for this.

How can I achieve this Issue? Any help is really appreciated.

Day 1
Target File-Emp.txt
Day 2
# 2  
Old 09-23-2011
you want logic
# 3  
Old 09-23-2011
Thanks for you reply. I am new to unix. If any ideas are really helpful for me.
# 4  
Old 09-23-2011
about your job you have to write a script for the same logic either in perl or shell.
and then rum that script by Unix commands.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

awk to create variables to pass into a bash loop to create a download link

I have created one file that contains all the necessary info in it to create a download link. In each of the lines /results/analysis/output/Home/Auto_user_S5-00580-6-Medexome_67_032/plugin_out/FileExporter_out.67... (8 Replies)
Discussion started by: cmccabe
8 Replies

2. AIX

Do i create a new lv ?

Currently directory /home/apps/fs_1 on both servers A and B is mounted on /dev/hd1. I am assuming it should have separate filesystem, with its own lv as fs_1_lv to which /home/apps/fs_1 should be mounted, am I correct ? For Example: Server A: Filesystem GB blocks Free %Used Iused... (2 Replies)
Discussion started by: aix_admin_007
2 Replies

3. Homework & Coursework Questions

Create script to add user and create directory

first off let me introduce myself. My name is Eric and I am new to linux, I am taking an advanced linux administration class and we are tasked with creating a script to add new users that anyone can run, has to check for the existence of a directory. if the directory does not exist then it has... (12 Replies)
Discussion started by: pbhound
12 Replies

4. Red Hat

how to create a Filesystem

Hi everybody, I work with UNIX-AIX OS, I have to install db2 connect , somebody could explain to me how to create a Filesystem?, user, group, and password? ( I read a little and I know there many types of Filesystems) I have no idea how to do it, Linux version 2.6.18-92.el5... (2 Replies)
Discussion started by: lauelmar
2 Replies

5. Solaris

how to create

Hi, I am new to solaris10. I want to add a user without prompting for any password, while logging to his machine Can someone tell me how to do that??? Thiru (2 Replies)
Discussion started by: tirupathiraju_t
2 Replies

6. Shell Programming and Scripting

cannot create

i am creating a shell script to generate a file format. i want to register each and every activity in the log file. here are the commands which i have given, Don't know why i am getting error. v_log_loc="$APPLCSF/log"; export v_log_loc v_logfile=${p_po_requestid}_LOG; export v_logfile ... (4 Replies)
Discussion started by: aindurkhya
4 Replies

7. HP-UX

create user

I need to create new user from the root.which command can i used ? (2 Replies)
Discussion started by: magasem
2 Replies

8. Solaris

Create a fs

hello sorry but i'm beginning with solaris (i use Aix) How can I create a new filesystem with solaris 9 ? (and define the size ). I find newfs and mkfs but i don't know how use it Thank you (3 Replies)
Discussion started by: pascalbout
3 Replies

9. UNIX Desktop Questions & Answers

How do I create desktop icons for the shell programs I create???

I am a bash shell programmer and I create programs on occasional basis. Now, I dont want my programs to be run by typing out its name at a command line. I want to make it as user friendly as possible. I want to create icons on the desktop so users can click on it. mind you, I said "desktop... (7 Replies)
Discussion started by: TRUEST
7 Replies

10. IP Networking

How to create new a/c that ...

how to create a new a/c and use it for webhosting such as my domain is and i wanan host on that a/c :) (1 Reply)
Discussion started by: irwan
1 Replies
Login or Register to Ask a Question