Click here to Skip to main content
15,562,223 members
Home / Discussions / Database
   

Database

 
AnswerRe: How to sort result if data fields contains both numeric and character value Pin
Eddy Vluggen19-May-12 1:32
professionalEddy Vluggen19-May-12 1:32 
QuestionExcel, OleDb, ACE, and skipping header rows Pin
PIEBALDconsult17-May-12 11:46
professionalPIEBALDconsult17-May-12 11:46 
AnswerRe: Excel, OleDb, ACE, and skipping header rows Pin
Jörgen Andersson17-May-12 12:39
professionalJörgen Andersson17-May-12 12:39 
GeneralRe: Excel, OleDb, ACE, and skipping header rows Pin
PIEBALDconsult17-May-12 15:20
professionalPIEBALDconsult17-May-12 15:20 
GeneralRe: Excel, OleDb, ACE, and skipping header rows Pin
Jörgen Andersson17-May-12 21:36
professionalJörgen Andersson17-May-12 21:36 
GeneralRe: Excel, OleDb, ACE, and skipping header rows Pin
PIEBALDconsult21-May-12 9:38
professionalPIEBALDconsult21-May-12 9:38 
GeneralRe: Excel, OleDb, ACE, and skipping header rows Pin
Jörgen Andersson21-May-12 10:59
professionalJörgen Andersson21-May-12 10:59 
QuestionSerial number in SQL Pin
draghu17-May-12 1:17
draghu17-May-12 1:17 
Hello,

I have a table ABC with two columns NAME and SEQUENCE. The valid values of sequence are from 1..50.

The table may not have all the Sequence number. For example following is the data in my table..

NAME SEQUENCE
------------------------
Jonh| 5
Amy| 1
Suresh| 3



I need a SQL to get the data like

NAME SEQUENCE
------------------------
Amy| 1
| 2
Suresh| 3
| 4
Jonh | 5
|6
|7
..
..
..
|50


Basically I want to have rows for the sequence numbers which are not present i my table.

I thought of using the following query to generate a sequence and then join, but does not help

SQL
select rownum  from dual connect by rownum <=50


I tried something like

SQL
with temp as (select name, sequence from abc where supp_ref_order is not null order by sequence )
 select rownum as num, temp.name from dual, temp connect by rownum <=50 where temp.sequence =num

AnswerRe: Serial number in SQL Pin
Pablo Aliskevicius17-May-12 3:48
Pablo Aliskevicius17-May-12 3:48 
AnswerRe: Serial number in SQL Pin
Andy_L_J17-May-12 21:51
Andy_L_J17-May-12 21:51 
GeneralRe: Serial number in SQL Pin
draghu17-May-12 23:11
draghu17-May-12 23:11 
QuestionSybase DB access in windows 7 Pin
VenkataRamana.Gali16-May-12 18:29
VenkataRamana.Gali16-May-12 18:29 
AnswerRe: Sybase DB access in windows 7 Pin
JohnsonLuis16-May-12 22:07
JohnsonLuis16-May-12 22:07 
QuestionOne to Many Relationships - Tabular Display Pin
eddieangel16-May-12 11:36
eddieangel16-May-12 11:36 
AnswerRe: One to Many Relationships - Tabular Display Pin
Jörgen Andersson16-May-12 12:26
professionalJörgen Andersson16-May-12 12:26 
GeneralRe: One to Many Relationships - Tabular Display Pin
eddieangel16-May-12 13:53
eddieangel16-May-12 13:53 
GeneralRe: One to Many Relationships - Tabular Display Pin
Jörgen Andersson17-May-12 2:51
professionalJörgen Andersson17-May-12 2:51 
GeneralRe: One to Many Relationships - Tabular Display Pin
eddieangel17-May-12 7:43
eddieangel17-May-12 7:43 
AnswerRe: One to Many Relationships - Tabular Display Pin
Mycroft Holmes16-May-12 13:47
professionalMycroft Holmes16-May-12 13:47 
AnswerRe: One to Many Relationships - Tabular Display Pin
PIEBALDconsult16-May-12 15:11
professionalPIEBALDconsult16-May-12 15:11 
AnswerRe: One to Many Relationships - Tabular Display Pin
vvashishta16-May-12 21:15
vvashishta16-May-12 21:15 
Questionexport to text file + SQL Pin
jojoba201115-May-12 19:02
jojoba201115-May-12 19:02 
AnswerRe: export to text file + SQL Pin
vvashishta15-May-12 21:48
vvashishta15-May-12 21:48 
AnswerRe: export to text file + SQL Pin
Sandeep Mewara15-May-12 21:53
mveSandeep Mewara15-May-12 21:53 
QuestionRe: export to text file + SQL Pin
jojoba201115-May-12 22:53
jojoba201115-May-12 22:53 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.