Ask Your Question

PChitnis's profile - activity

2016-03-03 19:08:44 +0200 marked best answer Base keeps crashing while making forms

I am using Libre Office 4.2.5.2 with Windows 7 Ultimate 32 bit OS. I am developing a database with back end as MySQL community edition on localhost and Libre Base as front end for a standalone use, at the first instance. The Base Handbook has been of immense help. But I am running into a peculiar problem. While fine tuning a form with table control, the moment I click on to another column Base crashes! The occurrence is random but once it starts the frequency increases rapidly! The changes saved in the form are lost during recovery. I don't think the problem is with the MYSQL as only test data is stored at this stage i;e; the files are very small. 3 GB is plenty of memory so that can't be a issue. What can the problem be?

2015-10-18 13:46:03 +0200 received badge  Famous Question (source)
2015-08-26 10:00:31 +0200 received badge  Famous Question (source)
2015-08-25 01:57:01 +0200 marked best answer How to (i) show (ii) record - calculated values on base form?

(i) I need to show in real time the sum/ difference/ division/ product of two fields in a form (not report) for data entry as a guide/check. By the way I am using Libre Base as front end for standalone MYSQL back end.

(ii) At another place I also need to store the data into an underlying table.

2015-07-04 16:42:08 +0200 received badge  Notable Question (source)
2015-07-04 16:42:08 +0200 received badge  Famous Question (source)
2015-07-04 16:42:08 +0200 received badge  Popular Question (source)
2015-04-17 16:47:42 +0200 received badge  Famous Question (source)
2015-03-23 06:03:47 +0200 marked best answer How to set the standard date format to dd/mm/yyyy centrally?

I am using Windows 7 Ultimate OS with date format set as dd/mm/yyyy. I wish to set the same format across the complete Libre Office (4.2) installation , instead of doing so each time e.g. each date column in every spreadsheet! The only choice offered by Tools->Options is selecting range of years interpreted for 2 digit entry. Am I missing some obvious?

2015-03-14 11:36:39 +0200 received badge  Famous Question (source)
2014-12-12 17:07:46 +0200 asked a question Where can one find a comprehensive list of libre basic methods?

In order to write macros one really needs a comprehensive list of the methods in basic e.g. getbyname(), getbyindex(), updaterow(), reload(), getcurrentvalue(). Is there a method to which can put in a new value like getcurrentvalue() gets current value of a control property?

2014-12-03 13:26:02 +0200 answered a question In Base, how can controls that do not store data in the database, only for macro evaluation, be created?

There is a nice work around described in Base Handbook Chapter 4 Forms page no. 107. Have a single record table with desired number and types of fields in addition to an id auto-increment key field. Link to this from the form with additions disabled. Controls on the form linked to this table can be used to call up macros.

2014-11-24 05:26:16 +0200 received badge  Notable Question (source)
2014-11-03 17:20:55 +0200 commented question How do I add a non-primary-key field that has unique values

Your requirement is not clear. I assume you already have a Primary Key which is auto-increment integer type. Do you need to have an additional key field where you fill in or generate values not linked or dependent on auto-incremented series? And of course how do you use this field! It should be possible to generate a date-time dependent series as key field.

2014-11-03 08:30:41 +0200 answered a question Base Form: How can an unusual (layered) 1:m relationship be handled?

Your problem is in the database set up. Draw a chart showing relationships using primary and foreign key concepts. You should be able to have a straight line relation from T1 to T2 to T3. The m, h and s fields appear to be Primary and foreign keys linking the tables, while x, y and z fields appear to be the actual data. The s key field in T3 appears to be superfluous, but if you need the info for some obscure reason avoid using the T1-T3 direct connection.

2014-10-25 15:48:58 +0200 received badge  Teacher (source)
2014-10-25 15:26:48 +0200 commented answer How may I set up the auto-value countering for a primary key in Base?

Its an alter table command. Something like {ALTER TABLE "table_name" ALTER COLUMN "column_name " RESTART WITH xx;}. Check Base Tutorial by Mariana. Keep in mind that restart number must be greater than highest existing entry in the primary index. If you must have the numbers in a continuous series do not use auto increment or have another (primary) key field which is manually filled. Check documentation in detail.

2014-10-25 08:49:25 +0200 answered a question How may I set up the auto-value countering for a primary key in Base?

Please allow me to state your question as I understand it! Your table has an auto-incrementing field. You have 37 (or say x) records in the table. The next record should be 37 (or x+1). But you are getting 40 (that is greater than x=1). Did you delete/erase some records? The auto-increment goes on adding to the last recorded value! So if you added serial no. 38 and 39 records and the erased these, the next record will be 40 not 38! Check "reset auto-increment" of your database. If you must have a serially numbered primary key do not use auto-increment.

2014-10-17 16:21:00 +0200 received badge  Popular Question (source)
2014-10-15 22:55:53 +0200 received badge  Notable Question (source)
2014-10-14 15:50:50 +0200 commented answer How to increase the number of master/slave fields in forms?

continuing please - I tried to add fields by separating additional fields with ";" but it does not work.

2014-10-14 15:44:08 +0200 received badge  Commentator
2014-10-14 15:44:08 +0200 commented answer How to increase the number of master/slave fields in forms?

I think I have not been able to put my question clearly enough. The tool for linking master/slave fields caters for 4 fields to be connected. I need to link 7 fields. Foreign keys from 7 different tables are to be transferred to the target table. I must not transfer these directly as intermediate level additional data is to be typed in. I am reading the data from source files into the single record "filter" table so that an add only table control linked with the filter table reads these. cont

2014-10-14 03:05:58 +0200 received badge  Popular Question (source)
2014-10-12 19:09:50 +0200 received badge  Notable Question (source)
2014-10-12 16:23:32 +0200 asked a question How to increase the number of master/slave fields in forms?

I am using MySQL as back end and have (now) worked out procedures and functions therein to be called from the form to minimise scripting in basic! I am using a "Filter" table as suggested in base handbook. The initial saving of the choice in this file is used to pass data to procedures and functions in MySQL. In one case, for the adding new record I have more than 4 fields to be passed from "Filter" table to the target table. Is there any way to increase the number of master/slave fields.

2014-10-12 16:16:26 +0200 answered a question How to read the value of a date field in a base form into macro?

Thanks JPL. I am not sure if Access2Base library is correctly linked with my database AND I will keep at it till its done! My "grouse" with LO is that Access2Base is not covered in the documentation. It took me 3 months to discover this resource! In the particular case I am using MySQL as back end and have (now) worked out procedures and functions therein to be called from the form to minimise scripting in basic! I am using a "Filter" table as suggested in base handbook. The initial saving of the choice in this file is used to pass data to procedures and functions in MySQL.

2014-10-12 15:59:54 +0200 received badge  Popular Question (source)
2014-10-10 12:33:46 +0200 asked a question How to read the value of a date field in a base form into macro?

I need to read the date entered into a base form date field, as a variable in a macro for using in a SQL command. I have been able to read numeric fields using GetCurrentValue but date field give an error. I have tried the snippets given in Access2Base library (value, getvalue etc) but to no avail.

2014-10-07 16:06:18 +0200 answered a question How to (i) show (ii) record - calculated values on base form?

Thanks Doug. It took me a little time to work on this particular problem and try it out. It works fine. A few details has to be added to meet my form requirements.

2014-10-01 23:08:01 +0200 received badge  Famous Question (source)
2014-10-01 18:14:53 +0200 answered a question How can one transmit data from one subform to another at the same or higher level?

The version of MySQL I am using does not require the extra double quotes! "UPDATE unitedcghs.selecting SET integery = '"& lastkwh &"' WHERE id = 1" works! In the macro I get the value of field in one form using xxx.getby value() into lastkwh and then update the other file, followed by updaterow() and refresh().

2014-10-01 17:54:52 +0200 answered a question To call a MySQL prodedure from within a form?

I did not wish to use a macro at first. Then, when I tried to run the "executeupdate", (as given in base handbook) it wouldn't go through. By trial and error I found that the version of MySQL I am using (latest) , does not call for file and field names to be put in double - double quotes.

By the way this was a part of another question I had asked which is also answered now.

2014-09-29 15:41:44 +0200 asked a question To call a MySQL prodedure from within a form?

I need to call (run) a procedure in MYSQL on selection in a list box in a form. The procedure does not take any parameter or return any value. Like the example in Base Handbook the first level form has a "filter table" with a few fields, one linked with the main listbox. On saving the selection in the "filter table", I wish to extract values from different tables and store these in other fields in the "filter table". The procedure in MySQL does the job fine but how to call it from within the form. Yes a macro should do the job but all examples/code snippets appear to be calling more macros demanding parameters to be passed. My attempts to jury rig a macro to just call a procedure without passing parameters or asking for a return value run into a wall! Say my procedure is named getlastxval(), how to call it? or how to say "CALL getlastxval()".

2014-09-28 18:32:42 +0200 received badge  Famous Question (source)
2014-09-28 13:32:24 +0200 commented question How can one transmit data from one subform to another at the same or higher level?

I could work out the problem if I find out what is wrong with the following line in macro : "UPDATE ""unitedcghs"".""selecting"" SET ""integery"" = lastkwh WHERE ""id"" = 1" I get the message "Basic syntax error. Unexpected symbol: Update...... (command reproduced). I need to update one field in a file with a single record with data extracted from another file. The data is successfully retrieved but the above command does not work.

Or I find a way to run a MySQL Procedure instead of a macro!

2014-09-26 19:01:54 +0200 received badge  Notable Question (source)
2014-09-26 19:01:54 +0200 received badge  Popular Question (source)
2014-09-17 10:03:53 +0200 answered a question Base keeps crashing while making forms

Robert (through bugzilla) working on the bug has linked the problem with height of tablecontrol. It seems the bug is legacy continuing from ooo. Keeping the height to more than 2 rows to be shown avoids the bug! My problem is solved but I do feel something needs to be done at programming level besides recording the matter in the documentation!

Thanks Robert.

Prakash Chitnis

2014-09-17 09:49:39 +0200 asked a question How can one transmit data from one subform to another at the same or higher level?

In an application, with tree structured sub forms, I need to transfer data from a lower form to a higher form, to be subsequently used in another branch, something like a reversed master/slave connection. Say the main form "A" table has fields A1, A2, A3 and one sub form "B" table has field B1, B2, B3 etc with fields A1 and B1 as master slave. I wish to read data in B3 into A3. The purpose is to use this data in a sub form "C" which is parallel to "B". I cannot put "C" sub form under "B" as I need to use data A2 in "C" and it has no linked field in table "B".

I really hope I have made myself clear!

Prakash Chitnis

2014-09-13 18:45:27 +0200 commented question Base keeps crashing while making forms

Copied the MySQL database to OpenSuse 13.1 and also copied the .odb file containing forms to the system. Tried working with the form. Same result! There certainly is a bug linked with the table control. PChitnis

2014-09-09 12:20:42 +0200 commented question Base keeps crashing while making forms

I filed a bug report [fdo#82774]. Robert was looking into it but no success. DierkH is requested to add the info to the report. That might get some additional attention. PChitnis