Rocket Universe Data load - universe

I'm trying to do a dataload into a Rocket Universe database. In going through the SQL Admin documentation, they give the following example, but very little in the way of describing what is going on with the config file. Can anyone shed a little more light on how the config file is defined? Any example resources on this? Thanks!
The following is an example of a data file:
tomr:"Tom" '"'Thomas Rand^29:77:240:"blond"green:Kevin
lisam:Lisa Michaels^28:66:130:"brown"brown:Troy
kellyv:Kelly Verock^37:72:180:"black"brown:none
paulv:Paul Vander^33:63:110:"brown"brown:Trisha
andyu:Andy Andrews^28:74:250:"blond"blue:none
ken:Ken Thompson^35:73:170:"grayy"blue:Peter
tim:Tim Tarks^35:75:180:"black"brown:none
steve:Steve Gough^35:68:180:"black"green:Nancy
ellen:Ellen Peters^33:75:220:"black"brown:Michael
derek:Derek Starks^34:66:120:"brown"brown:Karissa
The following example shows the corresponding configuration file:
FILE NUMBER: 1
LOCATION: ../dataloader/names2.data
Row Separator CHARACTER(S): 10
COLUMN SEPARATOR CHARACTER(S): :
QUOTE CHARACTER: "
ALTERNATE QUOTE CHARACTER: '
COLUMN NUMBER: 1
SOURCE FORMAT: RAW
COLUMN NUMBER: 2
SOURCE FORMAT: RAW
NEXT SEPARATOR CHARACTER(S): ^
COLUMN NUMBER: 3
SOURCE FORMAT: RAW
COLUMN NUMBER: 4
SOURCE FORMAT: RAW
COLUMN NUMBER: 5
SOURCE FORMAT: RAW
COLUMN NUMBER: 6
SOURCE FORMAT: RAW
WIDTH: 7
COLUMN NUMBER: 7
SOURCE FORMAT: RAW
COLUMN NUMBER: 8
SOURCE FORMAT: RAW
DESTINATION FILE:
LOCATION: TMP5950
AUTOSIZE: n
AUTOSIZE ROWS:
CREATE FILE: N
PARAMETER(S):
KEY COLUMN(S): KEY1
COLUMN NUMBER: KEY
COLUMN NAME: KEY1
SOURCE FILE NUMBER(S): 1
SOURCE COLUMN NUMBER(S): 1
COLUMN NUMBER: 1
COLUMN NAME: COL1
SOURCE FILE NUMBER(S): 1
SOURCE COLUMN NUMBER(S): 1
COLUMN NUMBER: KEY
COLUMN NAME: KEY2
SOURCE FILE NUMBER(S): 1
SOURCE COLUMN NUMBER(S): 2
COLUMN NUMBER: 2
COLUMN NAME: COL2
SOURCE FILE NUMBER(S): 1
SOURCE COLUMN NUMBER(S): 2
COLUMN NUMBER: KEY
COLUMN NAME: KEY3
SOURCE FILE NUMBER(S): 1
SOURCE COLUMN NUMBER(S): 3
COLUMN NUMBER: 3
COLUMN NAME: COL3
SOURCE FILE NUMBER(S): 1
SOURCE COLUMN NUMBER(S): 3
COLUMN NUMBER: 4
COLUMN NAME: COL4
SOURCE FILE NUMBER(S): 1
SOURCE COLUMN NUMBER(S): 4
CONVERSION TYPE: O
CONVERSION CODE: MD2
COLUMN NUMBER: 5
COLUMN NAME: COL5
SOURCE FILE NUMBER(S): 1
SOURCE COLUMN NUMBER(S): 8
>DATALOAD 5950.CONFIG

Does this define the config file enough for you - on page 5-42 there is a table.

Related

DMS - Show column Value only if another field equal specific Value

I'm trying to update my DMS script (JSON) with the role:
if column 'type' in table X =1 then show column 'name' in table Y value,
Else, show column 'name' in table Y as null;
Example:
Table X:
x_id
type
1
0
2
1
Table Y:
y_id
name
x_id
1
Yossi
2
2
Dan
1
Result for table Y after DMS process:
y_id
name
x_id
1
Yossi
2
2
null
1
Im using DMS to transform data from MySQL to Redshift.
Thanks

DAX compare to previous row and update upstream rows per condition

I am struggling in solving the following requirement on table attached.
I need to create a “Cross location” column where the result of the column looks on previous row and compares if the value on the location column matches.
If it does than the output is “No” but if it doesn’t it outputs “Yes” to all upstream rows of the Group which is indexed by the task number column.
** This is as small portion of the table which consists many groups and multiple task numbers which not always starts with 1 put per group is always consecutive.
Appreciate your support - table of interest attached in picture
enter image description here
Group task number location Cross location
A 1 CAT
A 2 CAT No
A 3 TGR Yes
A 4 TGR Yes
A 5 JGR Yes
A 6 CAT Yes
B 19 JGR
B 20 CAT Yes
B 21 CAT Yes
B 22 TGR Yes

Dax - Creating Column That Checks Dates Sequence

I have im my model table that contains data from reports based on monthly reporting of employees with column names "ReportDate" and enployye numbers.
I want to check that there is no gaps between the monthly dates to each employee with DAX.
For example:
EmpNum | ReportDate | CheckColumn
111 | 30.08.2019
111 | 30.09.2019
111 | 31.10.2019
222 | 30.08.2019
222| 31.10.2019 ----------> Here I want alert in my CheckColumn
Can someone find me a solution?
First you need to create a index column. Go to Edit Queries > Add Column > Index Column, starting with 1 for example.
Next you add a column with DAX which has a shift of 1 to the original column with this expression (make sure this column is from the same date format as your original column; Modelling > Format):
ShiftColumn = DATEVALUE(CALCULATE(MAX('Table'[Report Date]);FILTER('Table';'Table'[Index]=EARLIER('Table'[Index])-1)))
Next add the column with the check:
Column 2 = IF(DATEADD('Table'[Report Date].[Date];-1;DAY) = 'Table'[ShiftColumn]; TRUE(); FALSE())
The result:

How to create new column in power bi using given string match condition in first column and get value from another column, make new column?

My table is as follow
Col1 Col2
11_A 9
12_B 8
13_C 7
14_A 6
15_A 4
The table we need after the query
Col1 Col2 Col3
11_A 0 9
12_B 8 0
13_C 7 0
14_A 0 6
15_A 0 4
My query is
Col3 =
LEFT( 'Table'[Col2],
SEARCH("A", 'Table'[Col1], 0,
LEN('Table'[Col1])
)
)
Go to the query designer Add Column > Custom Column and use the following expression:
Update
You need two expressions (two new columns) for this:
One is:
'Your Column3
=if Text.Contains([Col1], "A") = true then [Col2] else 0
And the second:
'Your Column2
=if Text.Contains([Col1], "A") = false then [Col2] else 0
There are many ways to solve this,
Another easy way I like to do this with no-coding is to use Conditional Columns:
In PBI select Power Query Editor
Select your table on the edge of the screen
Select Add Column tab
Select Conditional Columns...
Name your column
Enter your condition as in the picture
You can add several conditions if you like
Don't forget to format your column to numeric if needed.
see picture
Adding columns using Conditional Column

importing column having character numeric in sas

I have two .csv files which i need to merge in sas.
The first file contains the data something like this :
column - products
3 - sales
3- sales
to more than 8 rows and then there are observations such as
00000ETH - sales
00000TRF - sales
The second file has data like this -
Columns - Products
3 - brand
4 - brand
0000ETH - brand
0000TRF - brand
Basically I have to make a new column "Brand" in the first file.
But when I import the first file , SAS makes the first observation as 000000003 while it remains as "3" in the second file. its taking the column as numeric because the first 8 rows are numeric in the first file
I have tried changing "TypeGuess rows" in the windows registry but it has not worked.
Please help !
If they're CSV files, TYPEGUESSROWS is not helpful as that is an excel setting. You can modify GUESSINGROWS directly in the proc import instead.
Try reading it in with data step, however- then you don't need to GUESS anythng.
data one;
length column $10 products $25; *or whatever is right;
infile "yourfile.csv" dlm=',' dsd lrecl=100 truncover; *or similar depending on your file;
input column $ products $;
run;
Similar for the other dataset.