I am trying to working on a table with two columns and developing an update strategy with an unconnected lookup. I am using the two columns PAYER_NM and ST_CD as keys. I had marked PAYER_NM as L port and ST_CD column as O/L/R port. The logic for lookup is on both the columns. When I try to make a change to one of the existing record with the same PAYER_NM but changing only the ST_CD column value. I want the only the ST_CD value of the record in the target table be updated for the same PAYER_NM column value. But the result for is that it keeps inserting a record into the target table instead of update. I would like to know how and what changes I need to make in my code to get what I need as above.
I tried using only one key column PAYER_NM and making other column ST_CD as non key column and vise versa.
Plese check session property - if its set to 'Insert' only. If not check the target properties and see if its insert only as well.
You can use UPDATE Starategy too to ensure update is working fine.
Related
I'm not quite sure whether the description for the column I'm working on is proper, so bear with me.
I got an Interactive Grid that I'm adapting, and it's supposed to work such as this:
It should select a name on the first column (an autocomplete field), followed by 3 columns, each with a checkbox. I need to order the data in the grid by the name in the first column. Problem is, I can't use an "order by" in the select statement, so I need to use APEX's "Column sorting".
The column for the name, however, isn't shown in the list to select the order by value. I only get the 3 checkboxes as an option to order it.
I tried having a copy of the name column, but this time, hidden (and not an autocomplete field), but it doesn't work either. Is there a workaround for this?
The IG will only allow you to sort by columns that have been enabled for sorting. By default, only columns of certain data types and maximum lengths are enabled for sorting, but you can override this for each column in your IG definition.
I want to create a second table from the first table using filters with dates and other variables as follows. How can I create this?
Following is the expected table and original table,
Go to Edit Queries. Lets say our base table is named RawData. Add a blank query and use this expression to copy your RawData table:
=RawData
The new table will be RawDataGrouped. Now select the new table and go to Home > Group By and use the following settings:
The result will be the following table. Note that I didnt use the exactly values you used to keep this sample at a miminum effort:
You also can now create a relationship between this two tables (by the Index column) to use cross filtering between them.
You could show the grouped data and use the relationship to display the RawDate in a subreport (or custom tooltip) for example.
I assume you are looking for a calculated table. Below is the workaround for the same,
In Query Editor you can create a duplicate table of the existing (Original) table and select the Date Filter -> Is Earliest option by clicking right corner of the Date column in new duplicate table. Now your table should contain only the rows which are having minimum date for the column.
Note: This table is dynamic and will give subsequent results based on data changes in the original table, but you to have refresh both the table.
Original Table:
Desired Table:
When I have added new column into it, post to refreshing dataset I have got below result (This implies, it is doing recalculation based on each data change in the original source)
New data entry:
Output:
I have a dataset with multiple tables and relationships between those tables which were auto detected when I connected to my PostgreSQL server.
But when I add a column using query, those relationships are no longer effective in the report view and all my graphs show 'blank' labels.
One thing I noticed is that in the Data view, the uuid which are used to make the relationships (my foreign keys in PSQL) appear with brackets and those brackets desappear after I add columns in query.
Before:
After:
I don't know if this helps.
I have tried adding columns with custom queries or simply duplicating an existing column.
I don't have any issue when adding columns using DAX.
Thanks,
Change the type of the column by yourself as one of the first steps in the query editor. You can either go with the brackets or without. Make sure its the same for every other key-/foreign key.
If you lost your relationship you can edit it by yourself. After your ID´s are proparly formatted go to Model (the last on the left pane) and drag and drop your relationship form one table to the other. This way it should work again.
I'm having difficulties running a SAS Data Intergration job.
One column needs to be removed from the target's structure,
but cannot be removed because of the NULL constraint.
Do I need to remove the constraint first?
How do I do that?
Thank you in advance,
Gal.
Does the physical table exists without the column? If so, then the constraint is only in the metadata. Recreate the metadata and you should be fine.
If the physical table exists with the column, then you need to recreate that table without the column. You will still need to refresh the table metadata for DI Studio to pick it up.
When I define a report region's SQL as SELECT * FROM some_table, all is fine until new columns are added to some_table -- then it breaks with a "ORAxxx No data found" error. It is easy to remediate, as it's enough to Apply Changes on the region again, even without making any changes. However, it does not make for a robust application.
Is there some combination of parameters that would allow SELECT * that does not break with new columns? It would be enough to apply any default formatting or heading to the new columns.
I'm aware I could construct the column list from data dictionary and then concatenate everything into the SELECT statement to evaluate, but this seems rather inelegant.
Normally is not recommended to use SELECT * queries because:
Returns all the columns, then the optimizer have less play to do.
It makes less robust the applications because adding new columns changes the result of the query giving unexpected results. Without SELECT *, I mean giving exactly the columns you need, adding new columns does not matter to the application.
Anyway, remember that creating a SELECT * for a view, oracle create the view replacing the * for all the columns, may be APPEX is making the same thing.
Currently your region source is (I presume) set to "Use Query-Specific Column Names and Validate Query". This means that a report column is defined explicitly for each column in the query, and the SQL is expected to be static.
If you change the region source to "Use Generic Column Names (parse query at runtime only)", then it will still work after a new column is added, with the column title defaulting to the column name.
There is another property "Maximum number of generic report columns" that defaults to 60 and must be set to a value big enough to accommodate any future columns added to the table.